//-------------------------------------------------------------------------------------------------
// <copyright file="SA1507.cs" company="OfficeClip LLC">
// Copyright (c) OfficeClip LLC.  All rights reserved.
// </copyright>
//-------------------------------------------------------------------------------------------------

namespace OfficeClip.OpenSource.StyleFix.Drivers
{
    using System;
    using System.Collections.Generic;
    using System.IO;
    using System.Text;
    using System.Text.RegularExpressions;

    public class SA1507
    {
        public static void Run(ref List<string> outputFileLines)
        {
            bool previousLineBlank = false;
            for (int i = outputFileLines.Count - 1; i >= 0; i--)
            {
                if ((outputFileLines[i].Length == 0) && previousLineBlank)
                {
                    outputFileLines.RemoveAt(i);
                }
                else
                {
                    previousLineBlank = (outputFileLines[i].Length == 0);
                }
            }
        }
    }
}
